package com.suray.wcs.service.system.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.suray.wcs.service.system.entity.ExceptionLogDB;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 操作日志 服务类
 * </p>
 *
 * @author cooper
 * @since 2019-06-26
 */
public interface IExceptionLogdbService extends IService<ExceptionLogDB> {

    List<ExceptionLogDB> getExceptionLogs(ExceptionLogDB wcsexceptiondb);

    List<ExceptionLogDB> getWCSErrsLog(ExceptionLogDB wcsexceptiondb);

    String toStackTrace(Exception e);

    boolean addExceptionLog(Exception e, Integer exceptionType, Integer taskId, String deviceName, Integer deviceStatus,
                            Integer errCode, String witnessUser);

    boolean addLowExceptionLog(String e, Integer exceptionType, Integer taskId, String deviceName,
                               Integer deviceStatus);

    void deleteThreeDaysEpLog(Integer days);

    int deleteExceptionLogById(Long[] exceptionLogIds);

    void cleanExceptionLog();

    List<Map<String, Object>> getExceptionDate(ExceptionLogDB exceptionLogDB);
}
